package com.wangzz.mallchat.common.user.service;

import io.netty.channel.Channel;

public interface WebSocketService {
    void connect(Channel channel);

    void handleLoginReq(Channel channel);

    /**
     * 登录成功
     *
     * @param code
     * @param id
     */
    void handleLoginSuccess(Integer code, Long id);

    /**
     * 用户下线
     * @param channel
     */
    void remove(Channel channel);

    void waitAuthorize(Integer code);

    /**
     * 连接认证
     * @param channel
     * @param token
     */
    void handleAuthorizeReq(Channel channel, String token);
}
